/*
 * Copyright (c) 2006, 2021, webrx.cn All rights reserved.
 *
 */
package cn.webrx.mapper;

import cn.webrx.entity.MyStudent;
import org.apache.ibatis.annotations.ResultMap;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

/**
 * <p>Project: mybatis2021 - StudentMapper
 * <p>Powered by webrx On 2021-07-19 10:49:46
 * <p>Created by IntelliJ IDEA
 *
 * @author webrx [webrx@126.com]
 * @version 1.0
 * @since 15
 */
@Repository
public interface StudentMapper {
    @Select("select * from t_student where id = #{id}")
    public Map<String, Object> queryById(int id);

    public List<String> queryNames();

    public List<MyStudent> queryAll();


    public List<MyStudent> showAll();

    @Select("select id,name from t_student where id = #{id}")
    @ResultMap("mys")
    public MyStudent showById(int id);

    public List<Map<String, Object>> selectAll();
    public List<Map<String, Object>> selectAll(Map<String, Object> map);
}
